<?php


class Crawl_sina_content_from_phone_json_library  extends Crawl_sina_from_phone_json_library{


    function make_data($result = NULL) {
        if(empty($result)) return false;
        $rs = array();

        if(preg_match('/"reposts_count": (\d*),/', $result, $matches))
            $rs['reposts_count'] = $matches[1];

        if(preg_match('/"comments_count": (\d*),/', $result, $matches))
            $rs['comments_count'] = $matches[1];

        if(preg_match('/"attitudes_count": (\d*),/', $result, $matches))
            $rs['attitudes_count'] = $matches[1];

        return $rs;
    }

    // 评论的ip
    function make_parameters() {

        $parameters['url'] = 'http://m.weibo.cn/status/'.$this->_ci->input->post('mid');
    	return $this->_parameters = $parameters;
    }


}
